load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")

go_library(
    name = "gossip",
    srcs = [
        "exchange.go",
        "gossip.go",
    ],
    importpath = "github.com/cockroachdb/cockroach/pkg/kv/kvserver/asim/gossip",
    visibility = ["//visibility:public"],
    deps = [
        "//pkg/kv/kvserver",
        "//pkg/kv/kvserver/allocator/storepool",
        "//pkg/kv/kvserver/asim/config",
        "//pkg/kv/kvserver/asim/state",
        "//pkg/roachpb",
        "//pkg/settings/cluster",
        "//pkg/util/hlc",
        "//pkg/util/protoutil",
        "//pkg/util/timeutil",
    ],
)

go_test(
    name = "gossip_test",
    srcs = [
        "exchange_test.go",
        "gossip_test.go",
    ],
    embed = [":gossip"],
    deps = [
        "//pkg/kv/kvserver/allocator/storepool",
        "//pkg/kv/kvserver/asim/config",
        "//pkg/kv/kvserver/asim/state",
        "//pkg/roachpb",
        "@com_github_stretchr_testify//require",
    ],
)
